package com.fr.report.script;

import java.io.Serializable;

public class Primitive
  implements Serializable
{
  private int idx = 0;
  public static final Primitive NULL = new Primitive(0);
  public static final Primitive ERROR_NAME = new Primitive(1);
  public static final Primitive ERROR_VALUE = new Primitive(2);
  public static final Primitive NOFILTER = new Primitive(3);
  private static final Primitive[] ps = { NULL, ERROR_NAME, ERROR_VALUE, NOFILTER };

  private Primitive(int paramInt)
  {
    this.idx = paramInt;
  }

  private Object readResolve()
  {
    return ps[this.idx];
  }

  public String toString()
  {
    if (this == ERROR_NAME)
      return "#NAME?";
    if (this == ERROR_VALUE)
      return "#VALUE?";
    return "";
  }
}